package com.mad.game.view.level;

import com.mad.game.system.Vector2;

public class Camera {

	public final Vector2 velocity = new Vector2(2,0);
	private Vector2 position ;
	
	public Vector2 getPosition() {
		return position;
	}
	
	public void setPosition(Vector2 position) {
		this.position = position;
	}
	
	public Camera() {
		this.setPosition(new Vector2(this.velocity.getX(),0));
	}

	public Camera(Vector2 position){
		this.setPosition(position);
	}
	
	public void moveLeft() {
		this.position.changeXByDelta(this.velocity.getX());
	}

	public void moveRight(){
		this.position.changeXByDelta(this.velocity.invert().getX());
	}
	
}
